﻿{% extends "gma/base.html" %}
{% load mytag %}

<!-- CONTENT
  =====================================================================-->

{% block content %}

<div class="page__bd">
    <div class="weui-cells__title"> <i class="fa fa-address-card"></i>  基本数据</div>
    <div class="weui-cells">
        {% if user.avatar %}
        <a class="weui-cell weui-cell_access" href="{% url 'gma:gallery' user.avatar %}">
            <div class="weui-cell__bd"> <p>头像</p> </div>
            <div class="weui-cell__ft"> <img class="right_large_avatar" src="{{ user.avatar|cdn }}"> </div>
        </a>
        {% endif %}

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p>用户id</p> </div>
            <div class="weui-cell__ft">{{ user.id }}</div>
        </div>

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p>昵称</p> </div>
            <div class="weui-cell__ft">{{ user.nickname }}</div>
        </div>
    </div>

    <div class="weui-cells__title"> <i class="fa fa-mobile"></i> 最新登录数据 </div>
    <div class="weui-cells">
        <div class="weui-cell">
            <div class="weui-cell__bd"> <p> 渠道 </p> </div>
            <div class="weui-cell__ft"> {{ user.channel }} </div>
        </div>

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p> 登录方式 </p> </div>
            <div class="weui-cell__ft"> {{ user.login_type }} </div>
        </div>

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p> 登录城市 </p> </div>
            <div class="weui-cell__ft"> {{ user.country }} {{ user.province }} {{ user.city }}</div>
        </div>

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p> 登录IP </p> </div>
            <div class="weui-cell__ft">{{ user.last_login_ip }}</div>
        </div>

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p> 登录时间 </p> </div>
            <div class="weui-cell__ft">{{ user.last_login_time|date:"Y-m-d H:i:s" }}</div>
        </div>

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p> 登录手机 </p> </div>
            <div class="weui-cell__ft">{{ user.last_login_phone }}</div>
        </div>

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p> 登录版本 </p> </div>
            <div class="weui-cell__ft">{{ user.last_login_version }}</div>
        </div>

        <div class="weui-cell">
            <div class="weui-cell__bd"> <p> 登录设备 </p> </div>
            <div class="weui-cell__ft"> {{ user.last_login_device|slice:"0:30" }} </div>
        </div>
    </div>

    <div class="weui-cells__title"> <i class="fa fa-clipboard-list"></i>  行为日志 </div>
    <div class="weui-cells">
        <a class="weui-cell weui-cell_access" href="{% url 'gma:user_login_detail_list' user.id %}">
            <div class="weui-cell__bd"> 行为日志 </div>
            <div class="weui-cell__ft">
            </div>
        </a>
    </div>
</div>

<div class="page__ft">
    <a href="{% url 'gma:home' %}">
        <span class="bottom-logo">
           HiBao
       </span>
    </a>
</div>

{% endblock content %}

<!-- SCRIPT
  =====================================================================-->

{% block extra_js %}

{% endblock extra_js %}